package com.xxonehjh.demo.spring.core.services.extension;

import org.springframework.beans.BeansException;
import org.springframework.beans.factory.config.BeanPostProcessor;

/**
 * @author huangjh
 * @date 2021-7-15 9:59:13
 */
public class MyBeanPostProcessor implements BeanPostProcessor {

	@Override
	public Object postProcessBeforeInitialization(Object bean, String beanName) throws BeansException {
		System.out.println("call postProcessBeforeInitialization by MyBeanPostProcessor for 【" + beanName + "】 ... ");
		return bean;
	}

	@Override
	public Object postProcessAfterInitialization(Object bean, String beanName) throws BeansException {
		System.out.println("call postProcessAfterInitialization by MyBeanPostProcessor for 【" + beanName + "】 ... ");
		return bean;
	}

}
